﻿@model Dev101.Web.Models.Dev101Model
@{
    Layout = null;
}

<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>Index</title>
</head>
<body>
    <div>
        <h1>Home!</h1>
    </div>
    <div>
        <table>
            @foreach (var tag in Model.TagContainer.tagsForCurrentPage)
            {
                <tr>
                    <td>
                        @tag.name
                    </td>
                    <td>
                        @tag.numberOfCourses
                    </td>
                    <td>
                        @tag.tagpagecount
                    </td>
                    <td>
                        <a class="tagElem" href="#tagId=@tag.tagId" data-tagid="@tag.tagId">@tag.name</a>
                    </td>
                </tr>
                if (tag.courses != null)
                {
                    foreach (var course in tag.courses)
                    {
                        <tr>
                            <td>&nbsp;</td>
                            <td>@course.name</td>
                            <td>@course.duration</td>
                            <td>@course.duration.Hours|@course.duration.Minutes</td>
                        </tr>
                    }
                }
            }
        </table>
    </div>
    @Scripts.Render("~/bundles/jquery")
    @Scripts.Render("~/bundles/dev101")
</body>
</html>
